package com.zyasdk.service;

import android.content.Context;
import android.os.Handler;
import android.util.Log;

import com.zyasdk.util.AppInfoUtil;

import org.apache.http.NameValuePair;
import org.apache.http.message.BasicNameValuePair;

import java.util.ArrayList;
import java.util.List;

/**
 * 
 */
public class NewsService extends BaseService {

	public NewsService(Context context) {
		super(context);
	}

	public void GetNewsLock(Handler handler, String pck, String channel,
			String packid, String language, String pBindKey) {
		List<NameValuePair> params = new ArrayList<NameValuePair>();
		params.add(new BasicNameValuePair("PBindKey", pBindKey));
		params.add(new BasicNameValuePair("packages", pck));
		params.add(new BasicNameValuePair("channels", channel));
		params.add(new BasicNameValuePair("imei", AppInfoUtil.getIMEI(context)));
		params.add(new BasicNameValuePair("imsi", AppInfoUtil.getIMSI(context)));
		params.add(new BasicNameValuePair("packid", packid));
		params.add(new BasicNameValuePair("language", language));
		Log.i("result", "GetNewsLock + NewsService");
		ServiceTask.addTask(GetAPIUrl("GetNewsLock"), params, 1, handler, null);
	}
}
